package com.ruoyi.worklog.mapper;


import com.ruoyi.worklog.domain.WlStaffProject;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Author cw
 * @Date 2022/7/22 - 07 - 22
 * @Description com.ruoyi.worklog.mapper
 */
public interface WlStaffProjectMapper {


    //查询员工项目表：实际传入了WlStaffProject中的staffid、projectid
    public WlStaffProject selectWlStaffProject(WlStaffProject wlStaffProject);

   // public List<WlStaffProject> selectAllWlStaffProject();


    //查询所有项目信息

    //获取一个项目中所有员工id
    public List<Long> selectStaffIds(int project_id);
    //获取一个员工的所有项目id
    public List<Integer> selectProjectIds(long staff_id);
    /**
     * 增加员工id项目内容
     */
    public int insertWlStaffProject(WlStaffProject staffProlist);

    public int updateWlStaffProject(WlStaffProject staffProlist);

    //通过员工id和项目id删除一个具体关系
    public int deleteWlStaffProject(@Param("staff_id") long staff_id,@Param("project_id") int project_id);

    //通过员工id删除所有相关的项目关系
    public int deleteWlStaffProjectByStaffId(long staff_id);
    int deleteWlStaffProjectByStaffId2(Long[] staffIds);

    //通过项目id删除所有相关的员工关系
    public int deleteWlStaffProjectByProjectId(int project_id);



}
